package ihm;

import java.awt.EventQueue;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.border.EmptyBorder;
import javax.swing.JList;
import javax.swing.JToggleButton;
import javax.swing.JComboBox;
import javax.swing.JLabel;
import javax.swing.JTextPane;
import javax.swing.JTextArea;



public class FenetreModifArticle extends JFrame implements ActionListener
{

	private JPanel contentPane;
	private JButton btnAnnuler;
	private JButton btnModifier;
	private JComboBox comboBox;
	private JLabel lblArticles;
	private JButton btnAfficherContenu;
	private JTextPane textPane;
	private JTextArea txtContenuArticle;

	/**
	 * Launch the application.
	 */
	public static void main(String[] args)
	{
		EventQueue.invokeLater(new Runnable()
		{
			public void run()
			{
				try
				{
					FenetreModifArticle frame = new FenetreModifArticle();
					frame.setVisible(true);
				} catch (Exception e)
				{
					e.printStackTrace();
				}
			}
		});
	}

	/**
	 * Create the frame.
	 */
	public FenetreModifArticle()
	{
		setTitle("Modification de l'article");
		setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		setBounds(100, 100, 1000, 700);
		contentPane = new JPanel();
		contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));
		setContentPane(contentPane);
		
		btnAnnuler = new JButton("Annuler");
		btnAnnuler.setBounds(183, 227, 89, 23);
		btnAnnuler.addActionListener(this);
		contentPane.setLayout(null);
		contentPane.add(btnAnnuler);
		
		btnModifier = new JButton("Modifier");
		btnModifier.setBounds(292, 227, 89, 23);
		contentPane.add(btnModifier);
		
		comboBox = new JComboBox();
		comboBox.setBounds(98, 45, 157, 20);
		contentPane.add(comboBox);
		
		lblArticles = new JLabel("Articles :");
		lblArticles.setBounds(10, 38, 56, 34);
		contentPane.add(lblArticles);
		
		btnAfficherContenu = new JButton("Afficher contenu");
		btnAfficherContenu.setBounds(292, 44, 132, 23);
		contentPane.add(btnAfficherContenu);
		
		textPane = new JTextPane();
		textPane.setBounds(128, 121, 6, 20);
		contentPane.add(textPane);
		
		txtContenuArticle = new JTextArea();
		txtContenuArticle.setBounds(54, 91, 370, 112);
		contentPane.add(txtContenuArticle);
	}
	

	public void actionPerformed(ActionEvent e) 
	{
		if (e.getSource() == this.btnAnnuler)
		{
			System.exit(0);
		}
	}
}
